<template>
  <div class="scroll-view-demo10">
		<ynet-scroll-view
			ref="scrollView"
			:scrolling-x="false"
			@scroll="onScroll"
		>
      <div class="scroll-view-item">
        组件展示
      </div>
			<div v-for="item in list" class="scroll-view-item" :key="item" @click="handleClick(item)">{{item.text}}</div>
		</ynet-scroll-view>
	</div>
</template>

<script>
import ynetScrollView from "@components/scroll-view/index";
  export default {
    components: {
      ynetScrollView
    },
    data() {
      return {
        list: [
          {text: "amount"},
          {text: "button"},
          {text: "button-tab"},
          {text: "cell-item"},
          {text: "cell-title"},
          {text: "check"},
          {text: "check-box"},
          {text: "field"},
          {text: "field-item"},
          {text: "icon"},
          {text: "input-amount"},
          {text: "input-item"},
          {text: "message-code"},
          {text: "number-keyboard"},
          {text: "popup"},
          {text: "popup-title-bar"},
          {text: "radio"},
          {text: "scroll-view"},
          {text: "stepper"},
          {text: "steps"},
          {text: "switch"},
          {text: "tab-bar"},
          {text: "tag"},
          {text: "transition"},
        ]
      }
    },
    methods:{
      handleClick(item){
        console.log("111")
        let url = "ynet-components/components/"+item.text+".html"
        let urls = "http://localhost:8080/"+url
        window.location.href = urls
        console.log(url)
        app.api.pushWindow(
          url
        )
      },
      onScroll() {

      }
    },
    created() {},
    mounted() {},
    watch: {},
    computed: {}
  }
</script>

<style lang="scss">
  .scroll-view-demo10{
    height: 100vh;
    .scroll-view-item{
      padding: 30px 0;
      text-align: center;
      font-size: 28px;
      border-bottom: .5px solid #efefef;
    }
  }
</style>

